package com.example.a2207_zh.adapter

import com.bumptech.glide.Glide
import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.example.a2207_zh.R
import com.example.a2207_zh.entity.Rent
import com.example.a2207_zh.entity.RoomEntity

class RoomAdapter(list:MutableList<Rent>) :BaseQuickAdapter<Rent,BaseViewHolder>(R.layout.item_room,list){
    override fun convert(holder: BaseViewHolder, item: Rent) {
        holder.setText(R.id.room_desc,item.title)
        holder.setText(R.id.room_youdian,item.labelDesc)
        holder.setText(R.id.room_price,"${item.price}元")
        Glide.with(context).load(item.indexPictureUrl).into(holder.getView(R.id.room_iv))
    }
}